<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <meta http-equiv="X-UA-Compatible" content="ie=edge">
    <title>P80 【例4-4】demo04.html</title>
</head>

<body>
    <script>
        function cal(num1, num2, fn) {
            return fn(num1, num2);
        }
        console.log(cal(45, 55, function (a, b) {
            return a + b;
        }));
        console.log(cal(10, 20, function (a, b) {
            return a * b;
        }));
    </script>
    <a href="../首页/page04.html">
        <h2>返回上一页面</h2>
    </a>
</body>

</html>